{% extends "base.html" %}

{% load i18n %}
{% load openid_tags %}
{% load svn_app_version %}
{% load analytics %}

{% block extra_head_base %}
    <link rel="stylesheet" href="{{ MEDIA_URL }}css/site_tabs.css" />
    <link rel="stylesheet" href="{{ MEDIA_URL }}pinax/css/topics.css" />
    <script type="text/javascript" src="{{ MEDIA_URL }}pinax/js/topics.js"></script>
    {% block extra_head %}{% endblock %}
{% endblock %}

{% block login %}
    {% if user.is_authenticated %}
        {% openid_icon openid user %}<b>{{ user }}</b> | <a href="{% url acct_email %}">{% trans "Account" %}</a> | {% if user.is_staff %}<a href="/admin/">{% trans "Admin" %}</a> | {% endif %}<a href="/openid/logout/?next={% url acct_logout %}">{% trans "Logout" %}</a>
    {% else %}
        <a href="{% url acct_login %}">{% trans "Login" %}</a> {% trans "or" %} <a href="{% url acct_signup %}"><b>{% trans "Sign up" %}</b></a>
    {% endif %}
{% endblock %}

{% block locale_switcher %}
    <form action="{% if request.user.is_authenticated %}{% url acct_language_change %}{% else %}/i18n/setlang/{% endif %}" method="post" id="locale_switcher">
        <select name="language" onchange="$('#locale_switcher').submit()">
            {% for lang in LANGUAGES %}
                <option value="{{ lang.0 }}"{% ifequal lang.0 LANGUAGE_CODE %} selected="selected"{% endifequal %}>{{ lang.1 }}</option>
            {% endfor %}
        </select>
    </form>
{% endblock %}

{% block logo_link_image %}<a href="{% url home %}"><img src="{{ MEDIA_URL }}pinax/images/logo.png" alt="Pinax"/></a>{% endblock %}

{% block tabs %}
{% comment %}
    <table>
        <tr>
            <td class="tab tab_home"><div><a href="{% url home %}">{% trans "Home" %}</a></div></td>
        </tr>
    </table>
{% endcomment %}
{% endblock %}

{% block right_tab %}
    {% if user.is_authenticated %}
        <table>
            <tr>
                <td class="tab rtab_profile"><div><a href="{% url profile_detail user %}">{% trans "Profile" %}</a></div></td>
                <td class="tab rtab_photos"><div><a href="{% url photos %}">{% trans "Photos" %}</a></div></td>
                <td class="tab rtab_blogs"><div><a href="{% url blog_list_all %}">{% trans "Blogs" %}</a></div></td>
                <td class="tab rtab_projects"><div><a href="{% url project_list %}">{% trans "Projects" %}</a></div></td>
                <td class="tab rtab_tribes"><div><a href="{% url tribe_list %}">{% trans "Tribes" %}</a></div></td>
                <td class="tab rtab_tweets"><div><a href="{% url tweets_you_follow %}">{% trans "Tweets" %}</a></div></td>
                <td class="tab rtab_bookmarks"><div><a href="{% url all_bookmarks %}">{% trans "Bookmarks" %}</a></div></td>
                <td class="tab rtab_swaps"><div><a href="{% url offer_list_all %}">{% trans "Swaps" %}</a></div></td>
                <td class="tab rtab_locations"><div><a href="{% url loc_yours %}">{% trans "Locations" %}</a></div></td>
                <td class="tab rtab_inbox"><div><a href="{% url messages_inbox %}">{% trans "Inbox" %} ({{ combined_inbox_count }})</a></div></td>
            </tr>
        </table>
    {% endif %}
{% endblock %}

{% block footer %}
<div class="legal">
    {% trans "&copy; 2008 &lt;your company here&gt;" %}
    - <a href="{% url about %}">{% trans "About" %}</a>
    - <a href="{% url terms %}">{% trans "Terms of Service" %}</a>
    - <a href="{% url privacy %}">{% trans "Privacy Policy" %}</a>
    - <a href="{% url dmca %}">{% trans "DMCA Notice" %}</a>
    - Version: {% svn_app_version %}
    - Django: {% svn_app_version "django" %}
</div>
{% endblock %}

{% block extra_body_base %}
    {% urchin %}
    <script src="{{ MEDIA_URL }}base.js" type="text/javascript"></script>
    {% block extra_body %}{% endblock %}
{% endblock %}
